
<body>
    <style>
        .am-form-group{ width: 100%}



    </style>
	<script src="<?php echo base_url() . 'public/'; ?>assets/js/theme.js"></script>


    <div class="am-cf admin-main">
        <div class=" admin-content">
    <div class="tpl-login" >
		<div class="tpl-login-content">
			<!--<div class="tpl-login-title">注册用户</div>-->

            <div class="am-popup-bd" style="margin-left: 35%; margin-top: 200px; width: 600px;">
                <span class="tpl-login-content-info">创建一个新的用户</span>
            <form class="am-form tpl-form-line-form">
				<div class="am-form-group">


					<input type="text" class="tpl-form-input username" name="username"  style="width: 100%" id="user-name" placeholder="用户名">

				</div>
                <div class="am-form-group">
                    <input type="text" class="tpl-form-input phone" name="phone"  style="width: 100%" placeholder="手机号">
                </div>
				<div class="am-form-group">
					<input type="password" class="tpl-form-input password1"   name="password1" style="width: 100%"   id="user-name" placeholder="请输入密码">
				</div>
				<div class="am-form-group">
					<input type="password" class="tpl-form-input password2" style="width: 100%" name="password2"placeholder="再次输入密码">
				</div>

            <!--    <div class="am-form-group">
                    <span> 选择一个类型</span>
                    <div  id="grouplist" >
                        <select name="grouplist" class="group" >
                            <?Php /*  foreach ($grouplist as $id=>$v){*/?>
                                <option  value="<?php /* echo$v['id'];  */?>"><?php /* echo$v['name'];  */?></option>
                            <?php /*} */?>
                        </select>
                    </div>
                </div>-->
                <div class="am-form-group" >
					<div type="button" class="am-btn am-btn-primary  am-btn-block tpl-btn-bg-color-success  tpl-login-btn" style="width: 300px;">立即注册</div>
				</div>
			</form>
            </div>
		</div>
	</div>
        </div>
    </div>

	<script src="<?php echo base_url() . 'public/'; ?>assets/js/amazeui.min.js"></script>
	<script src="<?php echo base_url() . 'public/'; ?>assets/js/app.js"></script>
	<script>
	$('.am-btn').click(
		function() {
			var data = {};
			data.username = $('.username').val();
			data.password1 = $('.password1').val();
            data.password2 = $('.password2').val();
			data.phone = $('.phone').val();
         /*   data.group = $(".group").val();*/
            var url = "<?php echo site_url(); ?>/Welcome/signaction";
			$.post(url,data,function(data) {
                if(data.code==0){
                    layer.msg('注册成功');
                    location.href = "<?php echo site_url(); ?>/Welcome/index";
                }else{
                    layer.msg(data.msg);
                }
			},'json');
		}
	);
	</script>
</body>
</html>